package com.project.controller;

import com.project.bean.UserBean;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.time.LocalDate;

@RequestMapping("my")
@RestController
public class MyTestController {
    @RequestMapping("test")
    public String test(){
        return "ok";
    }

    @RequestMapping("/getU")
    public UserBean getUser() throws Exception {
        UserBean user = new UserBean("小刘","222",10000, LocalDate.parse("1998-09-09"));
        return user;
    }
}
